#ifndef PAWN_H_
#define PAWN_H_

#include "../Game/Enums.h"
#include "Piece.h"

#include <string>

namespace Core
{
	class Pawn :
		public Piece
	{
	public:
		Pawn(Player * player, Square * square);
		~Pawn(void);

		bool isPromoted() const;
		void promotedTo(Piece * val);
		Piece * promotedTo() const;

		std::string name() const;
		ChType type() const;
	
	protected:	
		virtual void updateValidMoves();

	private:
		Piece * _prom;
		bool considerEatOrEnpassant(Move * mv) const;
		void considerPromotion(Move * mv) const;

	};
}
#endif
